package com.sun.showcase.client.domain.mall;

import org.apache.commons.lang3.builder.EqualsBuilder;
import org.apache.commons.lang3.builder.HashCodeBuilder;
import org.apache.commons.lang3.builder.ToStringBuilder;

public class OrderGoods implements java.io.Serializable{
	private static final long serialVersionUID = 5454155825314635342L;
    /**
     * 主键       db_column: id 
     */	
	private String id;
    /**
     * 订单ID       db_column: order_id
     */
	private String orderId;
    /**
     * 店铺商品ID       db_column: goods_id
     */
	private String goodsId;
    /**
     * 店铺商品名称       db_column: goods_name
     */
	private String goodsName;
    /**
     * skuId       db_column: sku_id
     */
	private String skuId;
    /**
     * skuName       db_column: sku_name
     */
	private String skuName;
    /**
     * 买家账号       db_column: user_id
     */
	private String userId;
    /**
     * 买家名称       db_column: user_name
     */
	private String userName;
    /**
     * 销售价格       db_column: sale_price
     */
	private Double salePrice;
    /**
     * 实际购买单价       db_column: deal_price
     */
	private Double dealPrice;
    /**
     * 购买数量       db_column: buy_num
     */
	private Integer buyNum;
    /**
     * 计量单位       db_column: cal_unit
     */
	private String calUnit;
    /**
     * 商品规格明细       db_column: specifications
     */
	private String specifications;
    /**
     * 商品主图地址       db_column: main_picture_address
     */
	private String mainPictureAddress;

	private String ifEvaluate;

	private Integer returnNum;
	//columns END

	public OrderGoods(){
	}

	public OrderGoods(
		String id
	){
		this.id = id;
	}

	public Integer getReturnNum() {
		return returnNum;
	}

	public void setReturnNum(Integer returnNum) {
		this.returnNum = returnNum;
	}

	public String getIfEvaluate() {
		return ifEvaluate;
	}

	public void setIfEvaluate(String ifEvaluate) {
		this.ifEvaluate = ifEvaluate;
	}

	public void setId(String value) {
		this.id = value;
	}

	public String getId() {
		return this.id;
	}
	public void setOrderId(String value) {
		this.orderId = value;
	}

	public String getOrderId() {
		return this.orderId;
	}
	public void setGoodsId(String value) {
		this.goodsId = value;
	}

	public String getGoodsId() {
		return this.goodsId;
	}
	public void setGoodsName(String value) {
		this.goodsName = value;
	}

	public String getGoodsName() {
		return this.goodsName;
	}
	public void setSkuId(String value) {
		this.skuId = value;
	}

	public String getSkuId() {
		return this.skuId;
	}
	public void setSkuName(String value) {
		this.skuName = value;
	}

	public String getSkuName() {
		return this.skuName;
	}
	public void setUserId(String value) {
		this.userId = value;
	}

	public String getUserId() {
		return this.userId;
	}
	public void setUserName(String value) {
		this.userName = value;
	}

	public String getUserName() {
		return this.userName;
	}
	public void setSalePrice(Double value) {
		this.salePrice = value;
	}

	public Double getSalePrice() {
		return this.salePrice;
	}
	public void setDealPrice(Double value) {
		this.dealPrice = value;
	}

	public Double getDealPrice() {
		return this.dealPrice;
	}
	public void setBuyNum(Integer value) {
		this.buyNum = value;
	}

	public Integer getBuyNum() {
		return this.buyNum;
	}
	public void setCalUnit(String value) {
		this.calUnit = value;
	}

	public String getCalUnit() {
		return this.calUnit;
	}
	public void setSpecifications(String value) {
		this.specifications = value;
	}

	public String getSpecifications() {
		return this.specifications;
	}
	public void setMainPictureAddress(String value) {
		this.mainPictureAddress = value;
	}

	public String getMainPictureAddress() {
		return this.mainPictureAddress;
	}

	public String toString() {
		return ToStringBuilder.reflectionToString(this);
	}
	
	public int hashCode() {
		return new HashCodeBuilder()
			.append(getId())
			.toHashCode();
	}
	
	public boolean equals(Object obj) {
		if(obj instanceof OrderGoods == false) return false;
		if(this == obj) return true;
		OrderGoods other = (OrderGoods)obj;
		return new EqualsBuilder()
			.append(getId(),other.getId())
			.isEquals();
	}
}

